<template>
    <div>
        <film-swiper>
            <div class="swiper-slide" v-for="(data,index) in imgList" :key="index">
              <div :style="{backgroundImage:'url('+data+')'}"
              style="height:200px;background-size:cover"></div>
            </div>
        </film-swiper>
        <!-- 只有在vue中，组件上写的class，style会自动传到组件的跟节点上 -->
        <film-header style="position:sticky;top:0px;z-index:100"></film-header>

        <!-- /film/nowplaying Nowplaying
        /film/comingson Comingsoon 嵌套路由 -->

        <router-view></router-view>
        <!-- caibi负责开发 -->
    </div>
</template>
<script>
import filmHeader from './film/FilmHeader'
import filmSwiper from './film/FilmSwiper'
export default {
  data () {
    return {
      imgList: ['https://pic.maizuo.com/usr/movie/962152780002ba0925aabe6bed25576f.jpg?x-oss-process=image/quality,Q_70', 'https://pic.maizuo.com/usr/movie/2adc4ba5d2bf6f2f2340d972eb98b580.jpg?x-oss-process=image/quality,Q_70', 'https://pic.maizuo.com/usr/movie/4b2143e7d65e4899b49c2eaca9e65c34.jpg?x-oss-process=image/quality,Q_70']
    }
  },
  components: {
    filmHeader,
    filmSwiper
  }
}
</script>
